class Failure {
  final String message;
  const Failure(this.message);

  @override
  String toString() => 'Failure: $message';
}

// 具体错误类型可扩展
class ServerFailure extends Failure {
  ServerFailure(super.message);
}